//
//  FrameBootcamp.swift
//  SwiftUiExercise
//
//  Created by 徐鹏 on 2023/6/23.
//

import SwiftUI

struct FrameBootcamp_09: View {
    var body: some View {
        Text("Hello, World!")
            .background(Color.green)
            //1 .frame(width: 300,height: 300,alignment: .leading)
            //.background(Color.red)
            //2            .frame(maxWidth: .infinity,maxHeight: .infinity, alignment: .center)
            //            .background(Color.red)
            .frame(height: 100)
            .background(Color.red)
            .frame(width: 150)
            .background(Color.orange)
            .frame(maxWidth: .infinity,alignment: .leading)
            .background(Color.pink)
            .frame(height: 400)
            .background(Color.green)
            .frame(maxHeight: .infinity,alignment: .top)
            .background(Color.yellow)
          
    }
}

struct FrameBootcamp_Previews: PreviewProvider {
    static var previews: some View {
        FrameBootcamp_09()
    }
}
